//
//  CAAnimation+SWAdd.m
//  QZMJ
//
//  Created by 腾程－ios1 on 16/12/20.
//  Copyright © 2016年 曾少伟. All rights reserved.
//

#import "CAAnimation+SWAdd.h"

@implementation CAAnimation (SWAdd)

@end

@implementation CAKeyframeAnimation (SWAdd)

+ (instancetype)keyAnimationWithKeyPath:(NSString *)path
               valus:(NSArray *)valus
            duration:(CGFloat)duration
         repeatCount:(NSInteger)repeatCount
     timingFunctions:(NSArray *)timingFunctions
            fillMode:(NSString *)fillMode
 removedOnCompletion:(BOOL)removedOnCompletion
     calculationMode:(NSString*)calculationMode
{
    CAKeyframeAnimation *keyAnimation = [CAKeyframeAnimation animationWithKeyPath:path];
    keyAnimation.values = valus;
    keyAnimation.repeatCount = repeatCount;
    keyAnimation.duration = duration;
    keyAnimation.timingFunctions = timingFunctions;
    keyAnimation.fillMode = fillMode;
    keyAnimation.removedOnCompletion = removedOnCompletion;
    keyAnimation.calculationMode = calculationMode;
    return keyAnimation;
}

@end
